import sys

import pygame

def run_test():
    pygame.init()
    screen = pygame.display.set_mode((1200, 800))
    pygame.display.set_caption('测试练习')
    screen.fill((100, 130, 200))

    image = pygame.image.load('images/1613491657491.bmp')

    image = pygame.transform.scale(image, (180, 100))

    image_rect = image.get_rect()
    screen_rect = screen.get_rect()
    image_rect.centerx = screen_rect.width / 2
    image_rect.centery = screen_rect.height / 2

    screen.blit(image, image_rect)

    pygame.display.flip()
    while True:
        for event in pygame.event.get():
            if event.type == pygame.QUIT:
                sys.exit()

if __name__ == '__main__':
    run_test()